How to add a command button.





In the Form Design view, choose the 'Command Button' button on the Toolbox to insert a command button. Click on the form to insert the 'Command Button' and follow the steps in the wizard.

    1) If the Database window is not activated, activate the Database window.
    2) Choose the 'Forms' tab in the Database window.
    < Forms tab >
    3) Select the desired form from the list box. (The selected form is highlighted.)
    4) Choose the 'Design' button. (The selected form appears in Design view, and the floating Toolbox appears.)
    5) Do one of the following:

      a) To create a command button using the wizard, do the following:

        1] Make sure the 'Control Wizard' button located in the Toolbox is depressed.
        < Control Wizard depressed and selected bound control >
        2] Choose the 'Command Button' button on the Toolbox.
        3] Position the mouse pointer on the form to select the location for the command button.
        4] Click the location for the command button on the form. (The Command Button Wizard appears.)
        5] Follow the wizard instructions.

      b) To create a command button without using the wizard, do the following:

        1] Choose the 'Control Wizard' button located on the Toolbox.
        NOTE: This turns OFF the wizard.
        2] Position the mouse pointer on the form to select the location for the command button.
        3] Click the location for the command button on the form. (The command button appears.)
        4] Select the 'View' menu and select 'Properties'. (The property sheet appears for the command button.)
        5] Choose the 'Event' tab in the 'Properties' window.
        6] Click on the 'On Click' property. (The Build button appears to the right of the property.)
        7] Do one of the following:

          a] Enter the name of the macro.
          b] Enter the name of the event procedure.
          c] Choose the 'Build' button. (The Choose Builder dialog box appears.)
          < Build button >

            1} Select the 'Macro Builder' to create a macro.

              a} Choose 'OK'. (The Macro Save As dialog box appears.)
              b} Enter the name of the macro in the 'Save As' dialog box.
              c} Choose 'OK'. (The Macro screen appears.)

            2} Select the 'Code Builder' to create code.

              a} Choose 'OK'. (The Macro Save As dialog box appears.)
              b} Enter the name of the macro in the 'Save As' dialog box.
              c} Choose 'OK'. (The Macro screen appears.)

        8] Choose the 'Format' tab in the 'Properties' window.
        9] Click on the 'Caption' property.
        10] Enter the desired text to appear on the command button.

    6) Select the 'File' menu and select 'Save' to save the form.


Knowledge-Pak Desktop Suite (TM) Edition 5
Copyright (c) 1994-1997 by ServiceWare Inc. Subject to the terms set forth in the end-user license agreement. All rights reserved.



2nd Opinion copyright © 1997 by McAfee Associates.
Subject to the terms set forth in the end-user license agreement. All rights reserved.